import request from '@/utils/request.js'

const patientApi = {
    selectAll() {
        return request.get('/patient/selectAll')
    },
    list(patientQuery) {
        return request.get('/patient/list', {params: patientQuery})
    },
    deleteById(id) {
        return request.delete(`/patient/deleteById/${id}`)
    },
    deleteAll(ids) {
        return request.delete(`/patient/deleteAll/${ids}`)
    },
    add(patient) {
        return request.post(`/patient/add`, patient)
    },
    selectById(id) {
        return request.get(`/patient/selectById/${id}`)
    },
    update(patient) {
        return request.put('/patient/update', patient)
    }
}

export default patientApi